In factory automation systems, a plurality of programmable controllers are prepared to control operations of each of various manufacturing facilities arranged on a manufacturing line. Various input devices (sensors, switches, etc.) and output devices (electromagnetic valves, motors, indicating lamps, etc.) set in the manufacturing facilities are connected to each of the programmable controllers. Each of the programmable controllers control operations of the output devices corresponding thereto based on input signals from the input devices connected thereto and conditions programmed in advance. All the programmable controllers are connected to a control system network and a programmable controllers set as a master station can transmits data to other programmable controllers. Thus, the conditions are usually received by a programmable controller from a programmable controller set as a master station. The respective programmable controllers collect, when necessary, information concerning operation states and the like of the manufacturing facilities, which are controlled by the other programmable controllers, through the control system network and use the collected information for the operation control of the output devices.
In many cases, a function of a gateway is allocated to at least one of the programmable controllers belonging to one control system network. The programmable controller with the gateway function (hereinafter abbreviated as “gateway PC” in some case) is connected to a monitoring apparatus through an information system network. The monitoring apparatus performs, via the gateway PC, monitoring of operation states of manufacturing facilities subjected to operation control by the gateway PC and each of manufacturing facilities subjected to operation control by the other programmable controllers, collection of information concerning a production state in a manufacturing line, logging of the respective programmable controllers (including the gateway PC), supply of control data to the respective programmable controllers (including the gateway PC), and the like. The control data sent from the monitoring apparatus to the programmable controllers (including the gateway PC) relates to relatively easy operation control, i.e., a high real time property is not required of the operation control.
It is possible to construct the control system network and the information system network as one network by employing, for example, ATM (Asynchronous Transfer Mode) technology. However, a network system that can be constructed at low cost and easily is preferable as a network system in factory automation. Therefore, in general, the information system network is constructed by using the Ethernet (registered trademark) and configured separately from the control system network in which a data update period needs to be guaranteed.
Nowadays, factory automation systems are introduced in various industries. Functions required of programmable controllers are diversified. Therefore, to flexibly cope with all these needs, a programmable controller of a building block type is being developed. In a programmable controller of this type, various block units such as a power supply unit, a central processing unit (CPU) unit, an I/O (Input/Output) analog unit, and an I/O digital unit are prepared so that desired functions can be allocated to the programmable controller by preparing predetermined block units depending on the need. In a gateway PC of the building block type, usually, in addition to the power supply unit, the CPU unit, and the respective I/O units, a control-system network unit connected to the control system network and an information-system network unit connected to the information system network are prepared.
For example, when transmitting control data from a management apparatus to the programmable controller, which is connected to the control system network, through the information network, first, control data is transmitted from the management apparatus to the gateway PC through the information system network. The control data transmitted to the gateway PC is received by the information-system network unit and, then, transmitted to the CPU unit through a system bus.
The CPU unit of the gateway PC judges, based on predetermined information prepared in advance, whether the received data is addressed to the CPU unit itself or to another predetermined programmable controller. When the received data is addressed to the CPU unit itself, the CPU unit executes processing for capturing the received data as control data for the CPU unit itself. When the received data is addressed to another predetermined programmable controller, the CPU unit outputs the received data to the control-system network unit through the system bus. The received data transmitted to the control-system network unit is transmitted to the control system network after performing a protocol conversion to allow the programmable controller belonging to the control system network to receive the data and is received by the predetermined programmable controller.
On the other hand, when transmitting data from a predetermined programmable controller connected to only the control system network to the monitoring apparatus, first, the data is transmitted to the gateway PC through the control system network. The data transmitted to the gateway PC is received by the control-system network unit and, then, transmitted to the CPU unit through the system bus. The CPU unit of the gateway PC judges a transmission destination of the received data based on the predetermined information prepared in advance, recognizes that the received data is addressed to the monitoring apparatus, and outputs the received data to the information-system network unit through the system bus. The received data transmitted to the information-system network unit is transmitted to the information system network after performing a protocol conversion to allow the monitoring apparatus to receive the data and is received by the monitoring apparatus.
The gateway PC controls operations of the manufacturing facilities corresponding thereto as well. Therefore, besides signals or data received by the information-system network unit and the control-system network unit, signals input to the I/O unit from the respective input devices corresponding thereto are also transmitted to the CPU unit of the gateway PC. When the signals inputs to the I/O unit are transmitted to the CPU unit, the CPU unit judges how the output devices corresponding thereto should be controlled and outputs a predetermined control signal to the I/O unit.
For example, assume that the gateway PC is to sequence-control operations of the manufacturing facilities corresponding to the gateway PC. In this case, the gateway PC needs to periodically output the predetermined control signal to the respective output devices at a short period based on signals periodically input to the I/O unit from the respective input devices at a short period and the conditions programmed in advance. In other words, the gateway PC needs to timely perform processing of the input signals from the respective input devices and output of control signals to the respective output devices on a real time basis.
While timely performing the processing of the input signals from the respective input devices and the output of the control signals to the respective output devices on a real time basis, to surely process transmission and reception to and from the management apparatus or the other programmable controllers, for example, in a programmable controller according to the invention described in Patent Document 1, when there is a data link request (including a message and a command) from an external apparatus and a data link request to the external apparatus during execution of a scan cycle for repeatedly performing the processing of the input signals from the respective input devices, the output of the control signals to the respective output devices, and the like, these data link requests are sequentially set in a reception queue or a transmission queue. The data link requests set in the reception queue or the transmission queue are processed after the execution of the scan cycle.
Patent Document 1: Japanese Patent Application Laid-open No. H11-65623